import { GLFolderContainer } from './GLFolderContainer'
import { GLFolderLike } from './GLFolderLike'

export abstract class GLItem {
  public available: boolean = false;

  constructor(private parentFolder: GLFolderLike, public name: string, public id: string) {
      if(parentFolder) {
        parentFolder.registerChild(this);
      }
  }

  getParentFolder() {
    return this.parentFolder;
  }

  isFolderContainer() {
    return "asFolder" in this;
  }
}
